package com.example.design.pattern.structure

import java.lang.reflect.Proxy

/**
 *享元模式就是共享相同的对象，避免对象泛滥造成资源浪费
 **/
fun main() {
    val map = mutableMapOf<String, Html>()
    map["body"] = Body()
    map["title"] = Title(map["body"]!!)
    map["bottom"] = Bottom(map["body"]!!)
}